package Demo;

public class Dogs extends Pets{
    private String types;
    public Dogs(){
        super("pet");
        types="柯基";
    }
    public Dogs(String types) {
        super("pet");
        this.types = types;

    }

    public String getTypes() {
        return types;
    }

    public void setTypes(String types) {
        this.types = types;
    }

    public void catchDisc() {
        System.out.println("狗抓飞盘");
    }

    @Override
    public String toString() {
        return "狗的名字："+getName();
    }
}
